package com.eastfair.home.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.eastfair.boot.request.PageParams;
import com.eastfair.boot.service.SuperService;
import com.eastfair.home.dto.VenueReportDrawingHistoryDTO;
import com.eastfair.home.entity.VenueReportDrawingHistory;
import com.eastfair.home.vo.VenueReportDrawingHistoryVO;

import java.util.List;

/**
 * <p>
 * 业务接口
 * 一键报馆图纸提交记录
 * </p>
 *
 * @author dq
 * @date 2022-10-31
 */
public interface VenueReportDrawingHistoryService extends SuperService<VenueReportDrawingHistory> {

    /**
     * 分页查询图纸提交历史VO.
     *
     * @param pageParams the page params
     * @return the page
     */
    Page<VenueReportDrawingHistoryVO> listHistoryVO(PageParams<VenueReportDrawingHistoryDTO> pageParams);

    /**
     * 分页查询图纸提交历史.
     *
     * @param pageParams the page params
     * @return the page
     */
    Page<VenueReportDrawingHistory> listHistory(PageParams<VenueReportDrawingHistoryDTO> pageParams);

    /**
     * 查询图纸提交历史.
     *
     * @param param the param
     * @return the list
     */
    List<VenueReportDrawingHistory> listHistory(VenueReportDrawingHistoryDTO param);

    /**
     * 获取报馆中指定图纸类型的最新一条提交记录.
     *
     * @param venueReportId the venue report id
     * @param drawingId     the drawing id
     * @return the last submit history
     */
    VenueReportDrawingHistory getLatestSubmitHistory(Long venueReportId, Long drawingId);

    /**
     * 保存报馆图纸提交历史.
     *
     * @param historyDTO the history dto
     * @return the venue report drawing history
     */
    VenueReportDrawingHistory saveVenueReportDrawingHistory(VenueReportDrawingHistoryDTO historyDTO);

    /**
     * 批量更新提交历史的审核状态.
     *
     * @param list the history dto
     * @return the boolean
     */
    boolean updateBatchAuditStatus(List<VenueReportDrawingHistoryDTO> list);

}
